package com.project.srtp.secure.dao.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.Table;
import javax.persistence.UniqueConstraint;
import java.time.LocalDateTime;

/**
 * @author 曹行阳
 * @version 0.1
 * @date 2025/6/15 17:45
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("t_signed_pre_key")
@Table(uniqueConstraints = @UniqueConstraint(columnNames = {"key_id", "user_id"}))
public class SignedPreKeyDO {
    @TableId(type = IdType.AUTO)
    private Long id;
    private String userId;
    private Integer keyId;
    private String publicKey;
    private String signature;
    private String cipher;
    private String salt;
    private Boolean active;
    private String timestamp;
    private LocalDateTime dtTimestamp;
}
